package com.liwbn.rbac.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.liwbn.rbac.model.Framemenu;
import com.liwbn.rbac.model.FramemenuExample;
import com.liwbn.rbac.vo.SideBar;

public interface FramemenuMapper {
    int countByExample(FramemenuExample example);

    int deleteByExample(FramemenuExample example);

    int deleteByPrimaryKey(Long id);

    int deleteByPrimaryKeys(List<Long> ids);

    long insert(Framemenu record);

    int insertSelective(Framemenu record);

    int insertBatch(List<Framemenu> records);

    List<Framemenu> selectByExample(FramemenuExample example);

    Framemenu selectByPrimaryKey(Long id);

    int updateByExampleSelective(@Param("record") Framemenu record,
            @Param("example") FramemenuExample example);

    int updateByExample(@Param("record") Framemenu record,
            @Param("example") FramemenuExample example);

    int updateByPrimaryKeySelective(Framemenu record);

    int updateByPrimaryKey(Framemenu record);

    /**
     * 获取菜单树
     * 
     * @param example
     * @return
     */
    List<SideBar> selectSideBarByExample(FramemenuExample example);

    /**
     * 获取父级菜单
     * 
     * @param example
     * @return
     */
    List<SideBar> selectParentSideBarByExample(FramemenuExample example);
}
